﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true"
    CodeBehind="ContractSalesInfo.aspx.cs" Inherits="Client_Revenue.ContractSalesInfo" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <h2>
        Contracts Sales details
    </h2>
    <table style="text-align: justify; vertical-align: top; padding: 10 0 0 10; width:100%">
        <tr>
            <td style="text-align: justify; vertical-align: top;">

                <asp:GridView ID="ClientsGridView" runat="server" AllowPaging="True" AllowSorting="True" AllowPaging="true"
                    AutoGenerateColumns="False" DataKeyNames="ClientId" OnSelectedIndexChanged="ClientsGridView_SelectedIndexChanged"
                    SelectedRowStyle-BackColor="LightGray" 
                    onpageindexchanging="ClientsGridView_PageIndexChanging">
                    <Columns>
                        <asp:CommandField ShowSelectButton="True" />
                        <asp:TemplateField HeaderText="Clients" SortExpression="ClientName">
                            <%--<EditItemTemplate>
                                <asp:TextBox ID="txtClientName" runat="server" Text='<%# Eval("ClientName") %>' ></asp:TextBox>
                            </EditItemTemplate>--%>
                            <ItemTemplate>
                                <asp:Label ID="Label1" runat="server" Text='<%# Eval("ClientName") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                    </Columns>
                    <SelectedRowStyle BackColor="LightGray"></SelectedRowStyle>
                    <AlternatingRowStyle BackColor="#CCCCCC"></AlternatingRowStyle>
                </asp:GridView>
            </td>
            <td>
                <asp:GridView ID="gvContractsSalesDetails" runat="server" AllowPaging="True" HorizontalAlign="Justify"
                    PagerSettings-Position="TopAndBottom" AllowSorting="True" AlternatingRowStyle-BackColor="#CCCCCC"
                    AutoGenerateColumns="False"  AllowPaging="true"
                    onpageindexchanging="gvContractsSalesDetails_PageIndexChanging" 
                    onrowcancelingedit="gvContractsSalesDetails_RowCancelingEdit" 
                    onrowediting="gvContractsSalesDetails_RowEditing" 
                    onrowupdating="gvContractsSalesDetails_RowUpdating" 
                    onselectedindexchanging="gvContractsSalesDetails_SelectedIndexChanging" 
                    onsorting="gvContractsSalesDetails_Sorting">
                    <AlternatingRowStyle BackColor="#CCCCCC"></AlternatingRowStyle>
                    <Columns>
                        <asp:CommandField ShowSelectButton="True" />
                        <asp:CommandField ShowEditButton="True" />
                        <asp:TemplateField HeaderText="Employee" SortExpression="LastName">
                           <%-- <EditItemTemplate>
                                <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("LastName") %>'></asp:TextBox>
                            </EditItemTemplate>--%>
                            <ItemTemplate>
                                <asp:Label ID="Label1" runat="server" Text='<%# Bind("LastName") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Role" SortExpression="RoleName">
                           <%-- <EditItemTemplate>
                                <asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("RoleName") %>'></asp:TextBox>
                            </EditItemTemplate>--%>
                            <ItemTemplate>
                                <asp:Label ID="Label4" runat="server" Text='<%# Bind("RoleName") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                      
                        <asp:TemplateField HeaderText="% Commission ">
                            <EditItemTemplate>
                                <asp:TextBox ID="txtCommission" runat="server" Text='<%# Bind("Commission") %>'></asp:TextBox>
                            </EditItemTemplate>
                            <ItemTemplate>
                                <asp:Label ID="Label2" runat="server" Text='<%# Bind("Commission") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Fee ($)">
                            <EditItemTemplate>
                                <asp:TextBox ID="txtFee" runat="server" Text='<%# Bind("Fee") %>'></asp:TextBox>
                            </EditItemTemplate>
                            <ItemTemplate>
                                <asp:Label ID="Label3" runat="server" Text='<%# Bind("Fee") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Contract Date">
                            <%--<EditItemTemplate>
                                <asp:TextBox ID="TextBox3" runat="server" Text='<%# Bind("StartDate") %>'></asp:TextBox>
                            </EditItemTemplate>--%>
                            <ItemTemplate>
                                <asp:Label ID="Label5" runat="server" Text='<%# Bind("StartDate") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                    </Columns>
                    <EmptyDataTemplate>
                        <p>
                            No Contract  found.</p>
                    </EmptyDataTemplate>
                    <PagerSettings Position="TopAndBottom"></PagerSettings>
                </asp:GridView>
            </td>
        </tr>
        <tr>
            <td>
            </td>
        </tr>
    </table>
</asp:Content>
